/*
 * @Author: 葛文杰
 * @Date: 2021/2/1 17:55
 * @Description: egg router 数据源配置
 */

'use strict';

module.exports = app => {
    const { router, controller } = app;

    const { dataSourceConfig } = controller;

    router.post('/dataSourceConfig/getDataSourceConfigById', dataSourceConfig.getDataSourceConfigById); // 获取数据源配置
    router.post('/dataSourceConfig/getDataSourceConfigList', dataSourceConfig.getDataSourceConfigList); // 获取数据源配置
    router.post('/dataSourceConfig/getDataSourcePullRateArray', dataSourceConfig.getDataSourcePullRateArray); // 获取数据源的获取数据频率
    router.post('/dataSourceConfig/insertDataSourceConfigInfo', dataSourceConfig.insertDataSourceConfigInfo); // 插入数据源配置
    router.post('/dataSourceConfig/updateDataSourceConfigInfoById', dataSourceConfig.updateDataSourceConfig); // 修改数据源配置
    router.post('/dataSourceConfig/deleteDataSourceConfigById', dataSourceConfig.deleteDataSourceConfigById); // 逻辑删除数据源配置
    router.post('/dataSourceConfig/changeDataSourceConfigEnable', dataSourceConfig.changeDataSourceConfigEnable); // 启停用数据源配置
};
